package com.cowcode.biz.impl;

import com.cowcode.biz.QuestionBiz;
import com.cowcode.dao.QuestionDao;
import com.cowcode.entity.Question;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * User: ljy
 * Date: 2021/6/26
 * Time: 15:30
 */
@Service
public class QuestionBizImpl implements QuestionBiz {
    @Resource
    private QuestionDao questionDao;
    @Override
    public List<Question> queryAll() {
        return questionDao.queryAll();
    }

    @Override
    public List<Question> queryTitle(String uname,String text,Integer sid,Integer page) {
        return questionDao.queryTitle(uname,text,sid,page);
    }

    @Override
    public boolean sendQuestion(Question question) {
        return questionDao.sendQuestion(question);
    }

    @Override
    public List<Question> queryByPage(int pgae,int pagecount) {
        return questionDao.queryByPage(pgae,pagecount);
    }

    @Override
    public int getCount() {
        return questionDao.getCount();
    }

    @Override
    public boolean deleteByQid(int qid) {
        return questionDao.deleteByQid(qid);
    }

    @Override
    public List<Question> query6() {
        return questionDao.query6();
    }
}
